package com.ruoyi.mdm.domain;

import java.math.BigDecimal;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 单位字典对象 unit
 *
 * @author ruoyi
 * @date 2024-04-03
 */
public class Unit extends BaseEntity {
	private static final long serialVersionUID = 1L;

	/**
	 * 单位编码
	 */
	@Excel(name = "单位编码")
	private String unitCode;

	/**
	 * 单位名称
	 */
	@Excel(name = "单位名称")
	private String unitName;

	/**
	 * 单位描述
	 */
	@Excel(name = "单位描述")
	private String unitDesc;

	/**
	 * 是否基础单位
	 */
	@Excel(name = "是否基础单位")
	private Integer baseFlag;

	/**
	 * 单位分组
	 */
	@Excel(name = "单位分组")
	private String unitGroup;

	/**
	 * 与基础单位的转换率
	 */
	@Excel(name = "与基础单位的转换率")
	private BigDecimal baseConvertRate;

	/**
	 * 与临接单位的转换率
	 */
	@Excel(name = "与临接单位的转换率")
	private BigDecimal adjoinConvertRate;

	/**
	 * 排序
	 */
	@Excel(name = "排序")
	private Integer sortNo;

	/**
	 * 主键
	 */
	private Long tableId;

	/**
	 * 行状态（0 正常, 1停用）
	 */
	@Excel(name = "行状态", readConverterExp = "0=正常,1=停用")
	private String status;

	/**
	 * 是否删除（0 存在, 2表示删除）
	 */
	private String delFlag;

	public void setUnitCode(String unitCode) {
		this.unitCode = unitCode;
	}

	public String getUnitCode() {
		return unitCode;
	}

	public void setUnitName(String unitName) {
		this.unitName = unitName;
	}

	public String getUnitName() {
		return unitName;
	}

	public void setUnitDesc(String unitDesc) {
		this.unitDesc = unitDesc;
	}

	public String getUnitDesc() {
		return unitDesc;
	}

	public void setBaseFlag(Integer baseFlag) {
		this.baseFlag = baseFlag;
	}

	public Integer getBaseFlag() {
		return baseFlag;
	}

	public void setUnitGroup(String unitGroup) {
		this.unitGroup = unitGroup;
	}

	public String getUnitGroup() {
		return unitGroup;
	}

	public void setBaseConvertRate(BigDecimal baseConvertRate) {
		this.baseConvertRate = baseConvertRate;
	}

	public BigDecimal getBaseConvertRate() {
		return baseConvertRate;
	}

	public void setAdjoinConvertRate(BigDecimal adjoinConvertRate) {
		this.adjoinConvertRate = adjoinConvertRate;
	}

	public BigDecimal getAdjoinConvertRate() {
		return adjoinConvertRate;
	}

	public void setSortNo(Integer sortNo) {
		this.sortNo = sortNo;
	}

	public Integer getSortNo() {
		return sortNo;
	}

	public void setTableId(Long tableId) {
		this.tableId = tableId;
	}

	public Long getTableId() {
		return tableId;
	}

	public void setStatus(String status) {
		this.status = status;
	}

	public String getStatus() {
		return status;
	}

	public void setDelFlag(String delFlag) {
		this.delFlag = delFlag;
	}

	public String getDelFlag() {
		return delFlag;
	}

	@Override
	public String toString() {
		return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
				.append("unitCode", getUnitCode())
				.append("unitName", getUnitName())
				.append("unitDesc", getUnitDesc())
				.append("baseFlag", getBaseFlag())
				.append("unitGroup", getUnitGroup())
				.append("baseConvertRate", getBaseConvertRate())
				.append("adjoinConvertRate", getAdjoinConvertRate())
				.append("sortNo", getSortNo())
				.append("tableId", getTableId())
				.append("status", getStatus())
				.append("delFlag", getDelFlag())
				.append("createBy", getCreateBy())
				.append("createTime", getCreateTime())
				.append("updateBy", getUpdateBy())
				.append("updateTime", getUpdateTime())
				.toString();
	}
}
